package org.ycx.doc.dao.model;

import java.io.Serializable;
import org.ycx.common.annotation.FormDesc;

@FormDesc(pk="moduleId")
public class DocModuleDefine implements Serializable {
    /** 模块编号 */
    @FormDesc(name="模块编号",maxLength=10,type=1)
    private Integer moduleId;

    /** 描述 */
    @FormDesc(name="描述",maxLength=500,type=0)
    private String actionDesc;

    /** 请求方式 */
    @FormDesc(name="请求方式",maxLength=10,type=1)
    private Integer actionType;

    /** 请求URL */
    @FormDesc(name="请求URL",maxLength=300,type=0)
    private String reqUrl;

    /** 请求类型 */
    @FormDesc(name="请求类型",maxLength=10,type=1)
    private Integer reqType;

    /** 请求报文 */
    @FormDesc(name="请求报文",maxLength=300,type=0)
    private String reqMsg;

    /** 回应类型 */
    @FormDesc(name="回应类型",maxLength=10,type=1)
    private Integer resType;

    /** 回应报文 */
    @FormDesc(name="回应报文",maxLength=300,type=0)
    private String resMsg;

    private static final long serialVersionUID = 1L;

    public Integer getModuleId() {
        return moduleId;
    }

    public void setModuleId(Integer moduleId) {
        this.moduleId = moduleId;
    }

    public String getActionDesc() {
        return actionDesc;
    }

    public void setActionDesc(String actionDesc) {
        this.actionDesc = actionDesc;
    }

    public Integer getActionType() {
        return actionType;
    }

    public void setActionType(Integer actionType) {
        this.actionType = actionType;
    }

    public String getReqUrl() {
        return reqUrl;
    }

    public void setReqUrl(String reqUrl) {
        this.reqUrl = reqUrl;
    }

    public Integer getReqType() {
        return reqType;
    }

    public void setReqType(Integer reqType) {
        this.reqType = reqType;
    }

    public String getReqMsg() {
        return reqMsg;
    }

    public void setReqMsg(String reqMsg) {
        this.reqMsg = reqMsg;
    }

    public Integer getResType() {
        return resType;
    }

    public void setResType(Integer resType) {
        this.resType = resType;
    }

    public String getResMsg() {
        return resMsg;
    }

    public void setResMsg(String resMsg) {
        this.resMsg = resMsg;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", moduleId=").append(moduleId);
        sb.append(", actionDesc=").append(actionDesc);
        sb.append(", actionType=").append(actionType);
        sb.append(", reqUrl=").append(reqUrl);
        sb.append(", reqType=").append(reqType);
        sb.append(", reqMsg=").append(reqMsg);
        sb.append(", resType=").append(resType);
        sb.append(", resMsg=").append(resMsg);
        sb.append("]");
        return sb.toString();
    }

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        DocModuleDefine other = (DocModuleDefine) that;
        return (this.getModuleId() == null ? other.getModuleId() == null : this.getModuleId().equals(other.getModuleId()))
            && (this.getActionDesc() == null ? other.getActionDesc() == null : this.getActionDesc().equals(other.getActionDesc()))
            && (this.getActionType() == null ? other.getActionType() == null : this.getActionType().equals(other.getActionType()))
            && (this.getReqUrl() == null ? other.getReqUrl() == null : this.getReqUrl().equals(other.getReqUrl()))
            && (this.getReqType() == null ? other.getReqType() == null : this.getReqType().equals(other.getReqType()))
            && (this.getReqMsg() == null ? other.getReqMsg() == null : this.getReqMsg().equals(other.getReqMsg()))
            && (this.getResType() == null ? other.getResType() == null : this.getResType().equals(other.getResType()))
            && (this.getResMsg() == null ? other.getResMsg() == null : this.getResMsg().equals(other.getResMsg()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getModuleId() == null) ? 0 : getModuleId().hashCode());
        result = prime * result + ((getActionDesc() == null) ? 0 : getActionDesc().hashCode());
        result = prime * result + ((getActionType() == null) ? 0 : getActionType().hashCode());
        result = prime * result + ((getReqUrl() == null) ? 0 : getReqUrl().hashCode());
        result = prime * result + ((getReqType() == null) ? 0 : getReqType().hashCode());
        result = prime * result + ((getReqMsg() == null) ? 0 : getReqMsg().hashCode());
        result = prime * result + ((getResType() == null) ? 0 : getResType().hashCode());
        result = prime * result + ((getResMsg() == null) ? 0 : getResMsg().hashCode());
        return result;
    }
}